﻿using System;
using System.Collections.Generic;
using Autodesk.Revit.DB;

namespace YArchitech.Plumbing
{
	public class PointComparer : IEqualityComparer<XYZ>
	{
		public bool Equals(XYZ x, XYZ y)
		{
			return x != null && y != null && x.DistanceTo(y) < 0.01;
		}

		public int GetHashCode(XYZ obj)
		{
			return obj.ToString().GetHashCode();
		}
	}
}
